A Formally Verified Interpreter for a Shell-Like Programming Language

نویسندگان

  • Nicolas Jeannerod
  • Claude Marché
  • Ralf Treinen
چکیده

The shell language is widely used for various system administration tasks on UNIX machines, as for instance as part of the installation process of software packages in FOSS distributions. Our mid-term goal is to analyze these scripts as part of an ongoing effort to use formal methods for the quality assurance of software distributions, to prove their correctness, or to pinpoint bugs. However, the syntax and semantics of POSIX shell are particularly treacherous. We propose a new language called CoLiS which, on the one hand, has well-defined static semantics and avoids some of the pitfalls of the shell, and, on the other hand, is close enough to the shell to be the target of an automated translation of the scripts in our corpus. The language has been designed so that it will be possible to compile automatically a large number of shell scripts into the CoLiS language. We formally define its syntax and semantics in Why3, define an interpreter for the language in the WhyML programming language, and present an automated proof in the Why3 proof environment of soundness and completeness of our interpreter with respect to the formal semantics.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Verified LISP Implementations on ARM, x86 and PowerPC

This paper reports on a case study, which we believe is the first to produce a formally verified end-to-end implementation of a functional programming language running on commercial processors. Interpreters for the core of McCarthy’s LISP 1.5 were implemented in ARM, x86 and PowerPC machine code, and proved to correctly parse, evaluate and print LISP s-expressions. The proof of evaluation requi...

متن کامل

A Functional Shell That Operates on Typed and Compiled Applications

Esther is the interactive shell of Famke, a prototype implementation of a strongly typed operating system written in the functional programming language Clean. As usual, the shell can be used for manipulating files, applications, data and processes at the command line. A special feature of Esther is that the shell language provides the basic functionality of a strongly typed lazy functional lan...

متن کامل

footils – Using the foo Sound Synthesis System as an Audio Scripting Language

foo is a versatile non-realtime sound synthesis and composition system based on the Scheme programming language (Eckel and González-Arroyo, 1994; Rumori et al., 2004; Rumori, 2005). It is mainly used for sound synthesis and algorithmic composition in an interactive type-render-listen-loop (the musician’s read–eval–print-loop) or in conjunction with an editor like the inferior mode of emacs. Unl...

متن کامل

Es: A shell with higher-order functions

In the fall of 1990, one of us (Rakitzis) re-implemented the Plan 9 command interpreter, rc, for use as a UNIX shell. Experience with that shell led us to wonder whether a more general approach to the design of shells was possible, and this paper describes the result of that experimentation. We applied concepts from modern functional programming languages, such as Scheme and ML, to shells, whic...

متن کامل

VLISP Byte Code Interpreter

The Veri ed Programming Language Implementation project has developed a formally veri ed implementation of the Scheme programming language. This report documents the byte-code interpreter, which executes a user program presented in the form of a binary image. It speci es several intermediate abstract machines, and proves that they are (successive) faithful implementations of the Vlisp operation...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2017